// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import router from './router'
import 'lib-flexible'
import './assets/css/style.css'
import './assets/css/font-awesome.css'
// 将axios挂载在  vue对象的原型下，以实现全局通用
import axios from 'axios'
Vue.prototype.axios = axios



// 这里的bus并不能全局同用
// var bus = new Vue()

Vue.filter('number', value => {
  if (value > 10000) {
    return (value / 10000).toFixed(2) + '万'
  } else {
    return value
  }

})
Vue.filter('titles', value => {

  if (value.length > 10) {
    return value.substr(0, 10) + "...."
  } else {
    return value
  }
})


new Vue({
  el: '#app',
  router,
  template: '<App/>',
  components: {
    App
  }

})

